
const routes = [
  {
    path: '/login',
    name: 'login',
    meta: { title: '登录' },
    component: () => import('../views/Login.vue')
  },
  {
    path: '/register',
    name: 'register',
    meta: { title: '注册' },
    component: () => import('../views/Register.vue')
  },
  {
    path: '/shopinfo/:id',
    name: 'shopinfo',
    meta: { title: '店铺详情' },
    component: () => import('../views/Shopinfo.vue')
  },
  {
    path: '/collect',
    name: 'collect',
    meta: { title: '我的收藏' },
    component: () => import('../views/Collect.vue')
  },
  {
    path: '/',
    name: 'tabbar',
    component: () => import('../views/Tabbar.vue'),
    children: [
      {
        path: '/index/home',
        name: 'home',
        meta: { title: '首页' },
        component: () => import('../views/index/Home.vue'),
      },
      {
        path: '/index/baobaotuan',
        name: 'baobaotuan',
        meta: { title: '爆爆团' },
        component: () => import('../views/index/Baobaotuan.vue')
      },
      {
        path: '/index/order',
        name: 'order',
        meta: { title: '订单' },
        component: () => import('../views/index/Order.vue')
      },
      {
        path: '/index/mine',
        name: 'order',
        meta: { title: '我的' },
        component: () => import('../views/index/Mine.vue')
      },
      {
        path: '/',
        redirect: '/index/home',
      },
      {
        path: '*',
        component: () => import('../views/NotFound.vue')
      }
    ]
  }
  
]
export default routes;